component.jasny-fileupload

jasny-fileupload-button

File upload button

Select fileChange ×
<h4 class="separator bottom">File upload button</h4>
<div class="fileupload fileupload-new margin-none" data-provides="fileupload">
  	<span class="btn btn-default btn-file"><span class="fileupload-new">Select file</span><span class="fileupload-exists">Change</span><input type="file" class="margin-none" /></span>
  	<span class="fileupload-preview"></span>
  	<a href="#" class="close fileupload-exists" data-dismiss="fileupload" style="float: none">&times;</a>
</div>

Code

@import "http://localhost/shared/components/modules/admin/forms/elements/jasny-fileupload/assets/css/fileupload.css";
@import "assets/components/modules/admin/ui/buttons/assets/buttons.less";

Usage

  1. Create a new LESS file (eg. styles.less)
  2. Copy & paste the above imports in the LESS file.
  3. Place the file in your project's document root.
  4. Load the LESS file into the <head> section of your HTML document, before any JavaScript files:

    <link type="stylesheet/less" href="styles.less" />

    NOTE  All the styles from the CORE package also need to be imported in this file, before the component imports.

  5. If you'd like to include other components on the same page, don't create multiple LESS files, but add all the imports in one file. You can create a LESS file for each page with just the resources used for that specific page, or you could create and use a single LESS file for the entire project.
  6. In production, compile the LESS file and use the resulting minified CSS file in the HTML document.

Scripts

BODY You should include the following scripts at the end of the HTML document, right before the closing </body> tag.

<script src="assets/components/modules/admin/forms/elements/jasny-fileupload/assets/js/bootstrap-fileupload.js?v=v1.2.3"></script>

jasny-fileupload-widget

File upload widget

Select fileChangeRemove
<h4 class="separator bottom">File upload widget</h4>
<div class="fileupload fileupload-new margin-none" data-provides="fileupload">
  	<div class="input-group">
    	<div class="form-control col-md-3"><i class="fa fa-file fileupload-exists"></i> <span class="fileupload-preview"></span></div>
    	<span class="input-group-btn">
    		<span class="btn btn-default btn-file"><span class="fileupload-new">Select file</span><span class="fileupload-exists">Change</span><input type="file" class="margin-none" /></span><a href="#" class="btn fileupload-exists" data-dismiss="fileupload">Remove</a>
    	</span>
  	</div>
</div>

Code

@import "http://localhost/shared/components/modules/admin/forms/elements/jasny-fileupload/assets/css/fileupload.css";
@import "assets/components/modules/admin/ui/buttons/assets/buttons.less";

Usage

  1. Create a new LESS file (eg. styles.less)
  2. Copy & paste the above imports in the LESS file.
  3. Place the file in your project's document root.
  4. Load the LESS file into the <head> section of your HTML document, before any JavaScript files:

    <link type="stylesheet/less" href="styles.less" />

    NOTE  All the styles from the CORE package also need to be imported in this file, before the component imports.

  5. If you'd like to include other components on the same page, don't create multiple LESS files, but add all the imports in one file. You can create a LESS file for each page with just the resources used for that specific page, or you could create and use a single LESS file for the entire project.
  6. In production, compile the LESS file and use the resulting minified CSS file in the HTML document.

Scripts

BODY You should include the following scripts at the end of the HTML document, right before the closing </body> tag.

<script src="assets/components/modules/admin/forms/elements/jasny-fileupload/assets/js/bootstrap-fileupload.js?v=v1.2.3"></script>